<%@ page language="java" contentType="text/html; charset=utf-8"%>
<%@ include file="/home/include/init_home.jsp" %>
<%@ page isErrorPage="true" %>
<%

	String nextUrl = request.getAttribute("nextUrl") == null ? "" : (String)request.getAttribute("nextUrl");
	if ("".equals(nextUrl)) {
		nextUrl = StringUtil.nvl(request.getHeader("Referer"));
	}

	//System.out.println("error_page:" + exception);
	if (exception == null) {
		exception = (Exception)request.getAttribute("exception");
	}

%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
	<title><%= HOME_NAME %></title>
	<link rel="stylesheet" type="text/css" href="/css/home.css"/>
	<script type="text/javascript">
	
	</script>
</head>
<body>
	<div id="Wrap"> 
		<div id="error">
	        <h1><img src="/images/home/sub_logo.gif" alt="서대문구 맞춤복지 검색서비스" /></h1> 
	        <h2>오류가 발생했습니다.</h2>   
	        
	        <br/><br/>
<%		if ("".equals(nextUrl)) { %>
        	<a href="/search.jsp" class="btn" >홈페이지</a>
        	<a href="#nohref" class="btn" onclick="history.back(-1);">이전으로 돌아가기</a>
<%		} else { %>
			<a href="<%= nextUrl %>" class="btn">확인</a>
<%		} %>
	    </div>

	</div>
</body>
</html>


